package com.vonchenchen.usbmuxd_android.usbmuxd.localconn.sharemem;

import android.os.ParcelFileDescriptor;

import com.vonchenchen.usbmuxd_android.usbmuxd.localconn.ILocalConnector;

import java.io.InputStream;
import java.io.OutputStream;

/**
 * Created by lidechen on 3/28/17.
 */

public abstract class AshmemConnector implements ILocalConnector {

    protected ParcelFileDescriptor mFd;

    protected InputStream mSocketInput;
    protected OutputStream mSocketOutput;

    protected int mSendBufferSize = -1;
    protected int mReceiveBufferSize = -1;

    @Override
    public InputStream getInputStream() {
        return mSocketInput;
    }

    @Override
    public OutputStream getOutputStream() {
        return mSocketOutput;
    }

    @Override
    public void setSendBufferSize(int size) {
        mSendBufferSize = size;
    }

    @Override
    public void setReceiveBufferSize(int size) {
        mReceiveBufferSize = size;
    }
}
